file(GLOB_RECURSE LAB2_SRC_CXX CONFIGURE_DEPENDS src/cpp/*.cpp src/cpp/*.hpp)
add_executable(LAB2_CXX ${LAB2_SRC_CXX})
target_link_libraries(LAB2_CXX PRIVATE ${FMT_LINK_LIB})

file(GLOB LAB2_SRC_C CONFIGURE_DEPENDS src/c/*.c src/c/*.h)
add_executable(LAB2_C ${LAB2_SRC_C})

# unix需要自行导线程库
if (UNIX)
    target_link_libraries(LAB2_CXX PRIVATE ${CMAKE_THREAD_LIBS_INIT})
    target_link_libraries(LAB2_C PRIVATE ${CMAKE_THREAD_LIBS_INIT})
endif ()
